Skip to content

Conversation

@joshua-arnold
Copy link
Contributor

@joshua-arnold joshua-arnold commented Dec 15, 2025

Summary

Adds a companion VSCode extension that streams logs from the SourceKit Bazel BSP server directly into a VSCode output channel, making it easier to monitor and debug BSP server activity without leaving the editor.

Motivation

At the moment, this extension only outputs important logs (errors) to VSCode tab. This will make it easy for people to identify errors instead of needing to setup a log stream and parse the large output.

Furthermore, we will be able to log other important warnings & information when needed.

Moving forward, hopefully we can start to support the remaining functionality in this extension:

  • Cursor / VSCode): Automatic generation of build, launch, and debug tasks
  • (Cursor / VSCode): Test explorer & ability to run tests from within the IDE by clicking the tests individually, similarly to Xcode
  • Automatic index and build graph updates when adding / deleting files and targets (in other words, allowing the user to make heavy changes to the project without needing to restart the IDE)

Changes

  • New VSCode extension (vscode-extension/)

    • Streams BSP server logs using macOS log stream command
    • Filters logs by subsystem (com.spotify.sourcekit-bazel-bsp) and category (extension)
    • Parses and formats log output for clean display in the "SourceKit Bazel BSP" output channel
    • Automatically starts on extension activation and cleans up on deactivation
  • New extension logger (Sources/SourceKitBazelBSP/SharedUtils/Logger.swift)

    • Added extensionLogger for user-facing messages intended to be shown in the VSCode extension
    • Refactored subsystem constant for reuse
  • CI updates (.github/workflows/ci.yaml)

    • Added step to build and compile the VSCode extension

Test plan

Tested the extension in the example project:

Screenshot 2025-12-14 at 8 18 07 PM

@joshua-arnold joshua-arnold changed the title Add VSCode extension Add VSCode extension for BSP server log streaming Dec 15, 2025
@joshua-arnold joshua-arnold marked this pull request as ready for review December 15, 2025 02:23
@joshua-arnold joshua-arnold requested a review from a team as a code owner December 15, 2025 02:23
Introduces a TypeScript-based VSCode extension that integrates with
the SourceKit Bazel BSP server. Includes basic extension scaffolding,
logger utility, and build configuration.
@rockbruno
Copy link
Member

Thanks @joshua-arnold! I'll give this a deeper look over the following days!

@josh-arnold-1
Copy link
Contributor

Thanks! No problem also if we want to go in another direction, just wanted to propose to get the ball rolling as I feel like the extension would be useful for eventually auto generating launch tasks etc, test running integration, + custom logic for detecting when new build files are added / modified in the work space etc.

@joshua-arnold joshua-arnold force-pushed the josh/vscode-extension branch 2 times, most recently from 82e419b to 41b5f5f Compare January 10, 2026 15:36
@joshua-arnold
Copy link
Contributor Author

@rockbruno updated! The extension should be super bare-bones now, ready to be built on top of. I also added some basic CI steps that ensure it will compile without warnings.

@rockbruno rockbruno merged commit 486d6f1 into spotify:main Jan 11, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants